package com.grao.waterschool.human.entiry.po;

import com.baomidou.mybatisplus.annotation.*;

import java.time.LocalDateTime;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

/**
 * 登录日志
 *
 * @author limk
 */
@Data
@TableName(value = "t_log_logon")
public class Logon {

    /**
     * ID
     */
    @Schema(description = "ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 用户
     */
    @Schema(description = "用户")
    @TableField(value = "username")
    private String username;

    /**
     * 登录或退出
     */
    @Schema(description = "登录或退出")
    @TableField(value = "type")
    private String type;

    /**
     * 设备
     */
    @Schema(description = "设备")
    @TableField(value = "device")
    private String device;

    /**
     * IP
     */
    @Schema(description = "IP")
    @TableField(value = "ip")
    private String ip;

    /**
     * 创建时间
     */
    @Schema(description = "创建时间")
    @TableField(value = "gmt_create", fill = FieldFill.INSERT)
    private LocalDateTime gmtCreate;
}
